Add ABSL_PRINTF_ATTRIBUTE to appropriate functions in
strings/internal/str_format/convert_test. Correct
TypedFormatConvertTest.Char, which was accidentally passing values of
types larger than int to StrPrint.
The author works at Google. Upstream applied this patch as Piper
revision 439388148 and exported it to GitHub; the Applied-Upstream URL
above points to the exported commit.
Null out supervisor bits in PA-RISC addresses before symbolizing, and
handle function descriptor tables correctly.
Change symbolize_test.cc to use 32-bit aligned addresses, allowing that
test to pass on PA-RISC.
The author works at Google. Upstream applied this patch as Piper
revision 428590564 and exported it to GitHub; the Applied-Upstream URL
above points to the exported commit.
Remove the test for absl::base_internal::NominalCPUFrequency() from OSS code
This is an internal-only function that should never by called by OSS code.
By its nature fails on unsupported platforms.
Google code has tests for this function on supported internal platforms.
This makes randen_test, randen_slow_test, and randen_hwaes_test essentially
identical, as is the intent.
The author works at Google. Upstream applied this patch as Piper
revision 405484423 and exported it to GitHub; the Applied-Upstream URL
above points to the exported commit.
Pay attention to the platform endianness when pulling bytes out of each
AES block, and use platform-endian round keys.
The author works at Google. Upstream applied this patch as Piper
revision 383878281 and exported it to GitHub; the Applied-Upstream URL
above points to the exported commit.
Replace randen’s internal 128-bit integer struct, u64x2, with
absl::uint128. This eliminates some code and improves support for
big-endian platforms.
The author works at Google. Upstream applied this patch as Piper
revision 383475671 and exported it to GitHub; the Applied-Upstream URL
above points to the exported commit.
Avoid using libstdc++'s implementation of std::hash<std::bitset> and
std::hash<std::vector> on big endian platforms in the implementation
of absl::Hash.
This is a workaround for a buggy implementation that results in many
collisions.
This patch is a subset of the referenced commit, which originally also changed
the mix function on arm64. The original message is as follows:
Alternative bit mixer for LowLevelHash on ARM
LowLevelHash's bit-mixer is inefficient on ARM because it calculates
a 128-bit product of two 64-bit numbers. On ARM, this requires a
sequence of two instructions with a high combined latency and poor
throughput. This change provides alternative bit-mixing code for ARM
that uses only 64-bit arithmetic (multiplication, xor, and
left-shifts) and speeds things up considerably.
The bit-mixing code for ARM was inspired by by Woothash[1] and
xxh3[1]. Once I landed on a sequence of operations that provided
good mixing, I used a test harness to search for the combination of
shift / rotate factors that provided the best mixing, as indicated
by SMHasher hash quality tests. The new mixing code passes 13 out of
15 of the hash quality test suites in SMHasher, with the two
failures being in the noise range: e.g. 1 collision vs. zero
expected in a keyset of ~8m keys.
(for double x and y) performs a double multiplication into a temporary
that, by standard, may have excess precision. The subsequent cast to int
discards the excess precision. However, the cast may examine the excess
precision during conversion, producing surprising results like
static_cast<int>(1.7 * 10) == 16
on certain systems. Correct this case by explicitly rounding 1.7 * 10
before casting it.
The author works at Google. Upstream applied this patch as Piper
revision 378922064 and exported it to GitHub; the Applied-Upstream URL
above points to the exported commit.
32-bit Intel CPUs use 80-bit floats for intermediate values, which can
change the results of floating point computations from what we normally
expect. Identify tests that are sensitive to the x87, and skip them when
we’re on 32-bit Intel.
The author works at Google. Upstream applied this patch as Piper
revision 378722613 and exported it to GitHub; the Applied-Upstream URL
above points to the exported commit.
Abseil generates discrete distributions using Walker’s aliasing
algorithm. This creates uniformly distributed buckets, each with a
probability of sending traffic to a different bucket. Abseil represents
a bucket as a pair
(probability of retaining traffic ×
alternate bucket if traffic is passed)
and a distribution as a vector of such pairs. For example, {(0.3, 1),
(1.0, 1)} represents a distribution with two buckets, the zeroth of
which passes 70% of its traffic to bucket 1 and the first of which holds
on to all its traffic.
This representation is not unique: When a bucket retains traffic with
probability 1, the alternate bucket is irrelevant. Continuing the
example above, {(0.3, 1), (1.0, 0)} _also_ represents a two-bucket
distribution where the zeroth bucket passes 70% of its traffic to the
first and the first hangs on to all traffic. Exactly what representation
Abseil generates for a given input is related to how much precision is
used in intermediate floating-point operations, which is an
architectural implementation detail. Remove sensitivity to that detail
by not examining the alternate bucket when the retention probability is
1.0.
The author works at Google. Upstream applied this patch as Piper
revision 372993410 and exported it to GitHub; the Applied-Upstream URL
above points to the exported commit.
Gbp-Pq: Name DiscreteDistributionTest-irrelevant-destination-buckets.diff
The author works at Google. Upstream applied this patch as Piper
revision 369926519 and exported it to GitHub; the Applied-Upstream URL
above points to the exported commit.
On 32-bit ARM, all functions are aligned to multiples of two bytes, and
the lowest-order bit in a function’s address is ignored by the CPU when
computing branch targets. That bit is still present in instructions and
ELF symbol tables, though; it’s repurposed to indicate whether the
function contains ARM or Thumb code. If the symbolizer doesn’t ignore
that bit, it will believe Thumb functions have boundaries that are off
by one byte, so instruct the symbolizer to null out the lowest-order bit
after retrieving it from the symbol table.
The author works at Google. Upstream applied this patch as Piper
revision 369254082 and exported it to GitHub; the Applied-Upstream URL
above points to the exported commit.
The author works at Google. Upstream applied this patch as Piper
revision 367481280 and exported it to GitHub; the Applied-Upstream URL
above points to the exported commit.
The libabsl_flags library only contains code when compiling with MSVC, which
Debian doesn't use. Skip compiling absl/flags/flag.cc, and make the Abseil flags
library header-only.
On some architectures, notably armel, Abseil needs symbols defined in
libatomic. Abseil does not currently have a well-developed system to
declare external library dependencies, so just have the linker determine
if anything needs libatomic and add the DT_NEEDED entry where necessary.
- To minimize the possibility of future ABI breakage, treat absl::any,
absl::optional, absl::string_view, and absl::variant as their own types
(rather than aliases for the std:: versions), and compile everything in an
inline namespace.
- Enable upstream's hardened build mode.
- Disable Intel SSE2 on i386, since Debian supports some i386 processors
without that extension. Keep it enabled on amd64, since all amd64 processors
have it.
- Disable Intel SSSE3 entirely, since no i386 processor supports it and Debian
supports amd64 processors without it.